package net.xju.service.impl;

import net.xju.dao.ConsultantDao;
import net.xju.entity.Consultant;
import net.xju.service.ConsultantService;

import java.util.List;

public class ConsultantServiceImpl implements ConsultantService {
    private ConsultantDao consultantDao = new ConsultantDao();

    @Override
    public Consultant login(String username, String password) {
        return consultantDao.login(username, password);
    }

    @Override
    public List<Consultant> list() {
        return consultantDao.list();
    }

    @Override
    public boolean insert(Consultant consultant) {
        return consultantDao.insert(consultant);
    }

    @Override
    public boolean update(Consultant consultant) {
        return consultantDao.update(consultant);
    }

    @Override
    public boolean delete(int id) {
        return consultantDao.delete(id);
    }
}